package cn.supermaster.management.web.service.system;

import cn.supermaster.management.common.domain.SystemDepartment;
import cn.supermaster.management.common.domain.SystemRole;
import cn.supermaster.management.common.entity.Ztree;
import cn.supermaster.management.common.response.WebResponse;
import org.springframework.ui.ModelMap;

import java.util.List;

/**
 * All rights Reserved, Designed By www.super-bytecode.com
 *
 * @ProjectName: supermaster-management
 * @Package: cn.supermaster.management.web.service.system
 * @ClassName: ISDepartmentService
 * @Description: []
 * <p> </p>
 * @Author: [Lance Ting]
 * @Date: 2021/2/19 22:02
 * @Version: V1.0
 * @Copyright: 2021 www.super-bytecode.com Inc. All rights reserved.
 * TODO: 注意,本文件Lance Ting所作,如果转载或使用请标明具体出处!
 **/
public interface ISDepartmentService {

    /*
     * ================================================
     *  页面跳转功能实现
     * ================================================
     */

    /**
     * @Description: []
     * <p></P>
     * @Title: skipDepartmentIndexHtml
     * @Author: Lance Ting
     * @Date: 2021-02-19
     * @Return: java.lang.String
     */
    String skipDepartmentIndexHtml();

    /**
     * @Description: []
     * <p></P>
     * @Title: skipDepartmentAddHtml
     * @Author: Lance Ting
     * @Date: 2021-02-19
     * @Param: modelMap
     * @Param: parentId
     * @Return: java.lang.String
     */
    String skipDepartmentAddHtml(ModelMap modelMap, Long parentId);

    /**
     * @Description: []
     * <p></P>
     * @Title: skipDepartmentModifyHtml
     * @Author: Lance Ting
     * @Date: 2021-02-19
     * @Param: modelMap
     * @Param: deptId
     * @Return: java.lang.String
     */
    String skipDepartmentModifyHtml(ModelMap modelMap, Long deptId);

    /**
     * @Description: []
     * <p></P>
     * @Title: skipBuildDepartmentTree
     * @Author: Lance Ting
     * @Date: 2021-02-19
     * @Param: modelMap
     * @Param: deptId
     * @Param: excludeId
     * @Return: java.lang.String
     */
    String skipBuildDepartmentTree(ModelMap modelMap, Long deptId, String excludeId);

    /*
     * ================================================
     *  Rest功能实现
     * ================================================
     */

    /**
     * @Description: []
     * <p></P>
     * @Title: queryDepartmentList
     * @Author: Lance Ting
     * @Date: 2021-02-19
     * @Param: department
     * @Return: java.util.List<cn.supermaster.management.common.domain.SystemDepartment>
     */
    List<SystemDepartment> queryDepartmentList(SystemDepartment department);

    /**
     * @Description: []
     * <p></P>
     * @Title: addDepartment
     * @Author: Lance Ting
     * @Date: 2021-02-19
     * @Param: department
     * @Return: cn.supermaster.management.common.response.WebResult
     */
    WebResponse addDepartment(SystemDepartment department);

    /**
     * @Description: []
     * <p></P>
     * @Title: modifyDepartment
     * @Author: Lance Ting
     * @Date: 2021-02-19
     * @Param: department
     * @Return: cn.supermaster.management.common.response.WebResult
     */
    WebResponse modifyDepartment(SystemDepartment department);

    /**
     * @Description: []
     * <p></P>
     * @Title: deleteDepartment
     * @Author: Lance Ting
     * @Date: 2021-02-19
     * @Param: deptId
     * @Return: cn.supermaster.management.common.response.WebResult
     */
    WebResponse deleteDepartment(Long deptId);

    /**
     * @Description: []
     * <p></P>
     * @Title: checkDepartmentNameUnique
     * @Author: Lance Ting
     * @Date: 2021-02-19
     * @Param: dept
     * @Return: java.lang.String
     */
    String checkDepartmentNameUnique(SystemDepartment dept);

    /**
     * @Description: [加载部门列表树]
     * <p></P>
     * @Title: loadAllDepartmentTree
     * @Author: Lance Ting
     * @Date: 2021-02-19
     * @Param:
     * @Return: java.util.List<cn.supermaster.management.common.entity.Ztree>
     */
    List<Ztree> loadAllDepartmentTree();

    /**
     * @Description: [加载部门列表树（排除下级）]
     * <p></P>
     * @Title: loadExcludeChildDepartmentTree
     * @Author: Lance Ting
     * @Date: 2021-02-19
     * @Param: excludeId
     * @Return: java.util.List<cn.supermaster.management.common.entity.Ztree>
     * @Throws:
     */
    List<Ztree> loadExcludeChildDepartmentTree(Long excludeId);

    /**
     * @Description: [加载角色部门（数据权限）列表树]
     * <p></P>
     * @Title: loadRoleDepartmentTree
     * @Author: Lance Ting
     * @Date: 2021-02-19
     * @Param: role
     * @Return: java.util.List<cn.supermaster.management.common.entity.Ztree>
     */
    List<Ztree> loadRoleDepartmentTree(SystemRole role);
}